import request from '@/utils/request'

// 查询问卷规则设置列表
export function listSurveyrules(query) {
  return request({
    url: '/questionnaire/surveyrules/list',
    method: 'get',
    params: query
  })
}

// 查询问卷规则设置详细
export function getSurveyrules(ruleId) {
  return request({
    url: '/questionnaire/surveyrules/' + ruleId,
    method: 'get'
  })
}

// 新增问卷规则设置
export function addSurveyrules(data) {
  return request({
    url: '/questionnaire/surveyrules',
    method: 'post',
    data: data
  })
}

// 修改问卷规则设置
export function updateSurveyrules(data) {
  return request({
    url: '/questionnaire/surveyrules',
    method: 'put',
    data: data
  })
}

// 删除问卷规则设置
export function delSurveyrules(ruleId) {
  return request({
    url: '/questionnaire/surveyrules/' + ruleId,
    method: 'delete'
  })
}
